﻿#ifndef __MYSQL_CFG_H__
#define __MYSQL_CFG_H__
#include "cfg/xml/ssXmlData.h"

using namespace StarSeeker;

class mysqlCfgRow : public ssICfgRow
{
public:
	SS_CFG_DATA_BEGIN
	SS_CFG_KEY1(id)
	SS_CFG_DATA(name)
	SS_CFG_DATA(inParam)
	SS_CFG_DATA(outParam)
	SS_CFG_DATA(sql)
	SS_CFG_DATA(queryType)
	SS_CFG_DATA_END(mysqlCfgRow)

	ssCfgInt32		id;
	ssCfgStr		name;
	ssCfgStr		inParam;
	ssCfgStr		outParam;
	ssCfgStr		sql;
	ssCfgInt32		queryType;
};

class mysqlCfg : public ssIXmlTable<mysqlCfgRow>
{
public:
	mysqlCfg()
	{
		m_path = "cfg/mysql_cfg.xml";
	}

	void SetPath(const char* path)
	{
		m_path = path;
	}

	void Clear()
	{
		m_map.clear();
	}
};

#endif
